HipAnimationTrack

This class uses multiplication for selecting the current frame, so, depending on the frame rate, it can cause frame skipping, for giving better freedom for speeding up animation

Constructors

this
this(string trackName, uint framesPerSecond, HipAnimationLoopingMode loopingMode)
Undocumented in source.

Members

Functions

addFrames
IHipAnimationTrack addFrames(HipAnimationFrame[] frame)

Use this version if you wish a more custom frame

addFrames
IHipAnimationTrack addFrames(IHipTextureRegion[] regions)
Undocumented in source. Be warned that the author may not have intended to support it.
getDuration
float getDuration()
Undocumented in source. Be warned that the author may not have intended to support it.
getFrameForProgress
HipAnimationFrame* getFrameForProgress(float progress)
Undocumented in source. Be warned that the author may not have intended to support it.
getFrameForTime
HipAnimationFrame* getFrameForTime(float time)
Undocumented in source. Be warned that the author may not have intended to support it.
loopingMode
HipAnimationLoopingMode loopingMode()
Undocumented in source. Be warned that the author may not have intended to support it.
loopingMode
HipAnimationLoopingMode loopingMode(HipAnimationLoopingMode loopingMode)
Undocumented in source. Be warned that the author may not have intended to support it.
name
string name()
Undocumented in source. Be warned that the author may not have intended to support it.
reset
void reset()
Undocumented in source. Be warned that the author may not have intended to support it.
reverse
bool reverse()
Undocumented in source. Be warned that the author may not have intended to support it.
reverse
bool reverse(bool setReverse)
Undocumented in source. Be warned that the author may not have intended to support it.
setFrame
void setFrame(uint frame)
Undocumented in source. Be warned that the author may not have intended to support it.
setFramesPerSecond
void setFramesPerSecond(uint fps)
Undocumented in source. Be warned that the author may not have intended to support it.
update
HipAnimationFrame* update(float dt)
Undocumented in source. Be warned that the author may not have intended to support it.

Variables

_loopingMode
HipAnimationLoopingMode _loopingMode;
Undocumented in source.
_reverse
bool _reverse;
Undocumented in source.
accumulator
float accumulator;
Undocumented in source.
currentFrame
uint currentFrame;
Undocumented in source.
frames
HipAnimationFrame[] frames;
Undocumented in source.
framesPerSecond
uint framesPerSecond;

Internal state management

isAdvancingForward
bool isAdvancingForward;
Undocumented in source.
isPlaying
bool isPlaying;
Undocumented in source.

Meta